-- GENERATED SPELL FOR [Felguard Elite] --


function spell0_8717(pUnit, Event) --@Blast Wave,Self--
pUnit:FullCastSpellOnTarget(16046,pUnit)
pUnit:RegisterEvent('Sorts_8717', 6269, 1)
end

function spell1_8717(pUnit, Event) --@Cleave,n/a--
pUnit:FullCastSpellOnTarget(15284,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_8717', 611, 1)
end

function spell2_8717(pUnit, Event) --@Mortal Strike,n/a--
pUnit:FullCastSpellOnTarget(13737,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_8717', 5347, 1)
end

function Sorts_8717(pUnit, Event)
local choix_sorts_8717 = math.random(0, 2)
if choix_sorts_8717 == 0 then
pUnit:RegisterEvent('spell0_8717', 1, 1)
end
if choix_sorts_8717 == 1 then
pUnit:RegisterEvent('spell1_8717', 1, 1)
end
if choix_sorts_8717 == 2 then
pUnit:RegisterEvent('spell2_8717', 1, 1)
end
end

function mob8717_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_8717', math.random(1500, 3000), 1)
end

function mob8717_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob8717_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob8717_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(8717, 1, 'mob8717_Action')
RegisterUnitEvent(8717, 2, 'mob8717_Leave')
RegisterUnitEvent(8717, 3, 'mob8717_Kill')
RegisterUnitEvent(8717, 4, 'mob8717_Die')
